In a computing apparatus for executing a task scheduling processing, signals are known as a technique for making a certain notification to a task from an operating system (OS). A signal is prepared for each event so as to notify an occurrence of a specific event to a specific task. The signal notification can be realized by software, for example, by changing a certain variable in a program. Some OSs provide such a scheme as to enable the registration of processings to be done by the task upon receiving a signal. This processing corresponding to the signal reception is often called a signal handler.
A general scheme of a signal and a signal handler is specifically described. First, a certain task #1 registers a signal handler A in response to a signal “a” and a signal handler B in response to a signal “b”, i.e. registers a signal handler for each kind of the signal. Thereafter, upon the notification of the signal “a” to the task #1 from the OS, the signal handler A is executed after interrupting the execution of the usual task #1. Likewise, upon the notification of the signal “b”, the signal handler B is executed. The generation of a signal corresponds to a certain event, e.g. the input of a command by a user, as described above, and a processing corresponding to the event can be defined (registered) as a signal handler for each individual task.
Further, some OSs provide such a scheme as to notify a specific signal at a time set by a task. In such OSs, the scheme of the signals can be utilized for a task to execute a processing in accordance with an actual time. In other words, a signal is sent from the OS to a task at a time when a required processing should be executed in the form of a signal handler. In this case, the precision of the processing to the actual time is required, and the signal handler needs to be executed immediately after the signal notification.
Generally, it is frequently required to immediately execute a specified processing in response to an occurrence of a certain event, and inventions made therefor are also known. For example, Japanese Unexamined Patent Publication No. H04-335441 (patent document 1) discloses a method for improving the immediacy of a command by setting the priority of a process corresponding to a command given from a specific user, terminal or the like at a high fixed value.
Normally, the signal handler is frequently executed by the context of the task. Specifically, the task is scheduled based on its priority and the signal handler corresponding to the notified signal is executed for the first time when the task is executed. Thus, there is a high possibility of executing a signal handler of a task having a lower priority at a delay from the signal notification according to the known technology, wherefore no processing immediately responsive to the signal notification can be executed. In order to avoid this problem, it is necessary to set the priority of the task at a sufficiently high value. As a result, tasks whose signal handlers are required to have readiness have higher priorities and the execution thereof is prioritized over processes having lower priorities even in cases other than the execution of the signal handlers.
However, the tasks whose signal handlers are required to have readiness are not necessarily required to be preferentially executed even in other processings. There are cases of desiring a design to prioritize other tasks for processings other than the execution of signal handlers. Accordingly, a freedom in designing priorities of tasks may be hindered by setting high priorities for tasks whose signal handlers are required to have readiness. This has been a problem in using the signal handlers.